//
//  DataManager.h
//  MobileZIPCodes
//
//  Created by Andreas Schwelling on 30.11.07.
//	http://www.andi.de/zipcodes/
// 
//  Released under the GNU General Public License.
//  See LICENSE for details.
//
//  Use at your own risk.
//



#import <Foundation/Foundation.h>
#import <UIKit/UIApplication.h>


@interface BrowseDataObject: NSObject {
	
	NSString			*_country;
	NSString			*_state;
	NSString			*_city;
	int					_browseType;
	
}
-(void)initialize;
-(NSString*)getCountry;
-(void)setCountry:(NSString*)country;

-(NSString*)getState;
-(void)setState:(NSString*)state;

-(int)getType;
-(void)setType:(int)type;

-(NSString*)getCity;
-(void)setCity:(NSString*)city;

@end



@interface DataManager : UIApplication {
	
	
	NSDictionary		*_remoteplist;
	
}

- (void) loadRemotePList;
- (NSDictionary*) getRemoteData;
- (NSDictionary*) getLocalCountriesData;
- (NSString*) getFileSizeForCountry:(NSString*)country;
- (NSMutableArray*) getLocalAvailableCountries;
- (NSMutableArray*) getRemoteAvailableCountries;
- (NSDictionary*) getPropertyList;
- (void) setPListParam: (id) param key: (id)keyval;
- (id) getPListParam: (id) key;
- (NSString*) getRemoteFileMirror:(NSString*)country;
- (void) deleteDatabaseFile:(NSString*)country;
- (NSString*) getRemoteFilesource:(NSString*)country;
- (NSString*) getDataBaseName:(NSString*)country;
- (NSMutableArray*) getInstalledCountries;
- (void) setInstalledCountries:(NSArray*)arr;
-(BOOL) isFavouredEntry:(NSString*) city forCountry:(NSString*)country;
-(void) removeFavouredEntry:(NSString*) city forCountry:(NSString*)country;
- (void) addFavouredEntry:(NSString*) city withState:(NSString*)state forCountry:(NSString*)country;
- (NSMutableArray*) getFavouredEntriesCountries;
- (NSDictionary*) getFavouredEntriesForCountry: (NSString*) country;

@end
